<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>土豆案例</title>
</head>
<style>
    .box {
        position: relative;
        width: 444px;
        height: 320px;
        background-color: pink;
        margin: 30px auto;
    }

    .box img {
        width: 100%;
        height: 100%;
    }

    .box::before {
        content:'';
        display: none;
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, .4) url(images/arr.png) no-repeat center;
    }

    /* 当我们鼠标经过了 土豆这个盒子，就让里面遮罩层显示出来 */
    .box:hover::before {
        /* 而是显示出来 */
        display: block;
    }
</style>

<body>
    <div class="box">
        <img src="images/tudou.jpg">
    </div>
</body>

</html>